package org.jeecg.modules.simulator.vo;

import lombok.Data;

import java.util.HashMap;
import java.util.Map;

/**
 * @program: simulator-b20240918
 * @description:
 * @author: renzhg
 * @create: 2024-10-04 13:55
 **/
@Data
public class LineCurInfoVo {
    String sceneCode;
    String timePt;

    String lineId;
    String lineName;

    Integer inLineInstantCurPersonNum=0;
    Integer inLineTotalCurPersonNum=0;

    Integer trainOnLineNum=0;//当前线路在线车辆数
    String lineTrainSchedulesName="";////当前线路列车时刻表名称
    Double trainFullLoadLine=0.0;//当前线路车辆满载率
    Double stationFullLoadLine=0.0;//当前线路车站满载率

    Integer inputInstantLineNum=0;//当前线路实时进站人数
    Integer outputInstantLineNum=0;//当前线路实时出站人数

    Integer inputTotalLineNum=0;//当前线路累计进站人数
    Integer outputTotalLineNum=0;//当前线路累计出站人数




//    Map<String, TrainPosition> allCurTrainPosition;
    //瞬时当前站点人数
    Map<String,Integer> stationInstantCurPersonNumMap=new HashMap<>();
    //瞬时当前站点想要进站人数
    Map<String,Integer> stationInstantCurWantInputPersonNumMap=new HashMap<>();
    //瞬时当前站点出站人数
    Map<String,Integer> stationInstantCurOutputPersonNumMap=new HashMap<>();
    //瞬时当前站点等车人数
    Map<String,Integer> stationInstantCurWaitPersonNumMap=new HashMap<>();
    //瞬时当前站点走行人数
    Map<String,Integer> stationInstantWalkingPersonNumMap=new HashMap<>();

    //累计当前站点人数
    Map<String,Integer> stationTotalCurPersonNumMap=new HashMap<>();

    //累计当前进站点人数
    Map<String,Integer> stationTotalCurWantInputPersonNumMap=new HashMap<>();
    //累计当前出站点人数
    Map<String,Integer> stationTotalCurOutputPersonNumMap=new HashMap<>();
    //累计当前等车人数
    Map<String,Integer> stationTotalCurWaitPersonNumMap=new HashMap<>();

    //累计当前走行人数
    Map<String,Integer> stationTotalWalkingPersonNumMap=new HashMap<>();




    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("LineCurInfoVo {")
                .append("lineId='").append(lineId).append('\'').append("lineName='").append(lineName).append('\'');
        sb.append("inLineInstantCurPersonNum='").append(inLineInstantCurPersonNum).append('\'');
        sb.append("inLineTotalCurPersonNum='").append(inLineTotalCurPersonNum).append('\'');
        sb.append("trainOnLineNum='").append(trainOnLineNum).append('\'');
        sb.append("lineTrainSchedulesName='").append(lineTrainSchedulesName).append('\'');
        sb.append("trainFullLoadLine='").append(trainFullLoadLine).append('\'');
        sb.append("stationFullLoadLine='").append(stationFullLoadLine).append('\'');


        sb.append("inputInstantLineNum='").append(inputInstantLineNum).append('\'');
        sb.append("outputInstantLineNum='").append(outputInstantLineNum).append('\'');

        sb.append("inputTotalLineNum='").append(inputTotalLineNum).append('\'');
        sb.append("outputTotalLineNum='").append(outputTotalLineNum).append('\'');


        sb.append(", stationInstantCurPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationInstantCurPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationInstantCurPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");

        sb.append(", stationInstantCurWantInputPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationInstantCurWantInputPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationInstantCurWantInputPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");


        sb.append(", stationInstantCurOutputPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationInstantCurOutputPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationInstantCurOutputPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");


        sb.append(", stationInstantCurWaitPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationInstantCurWaitPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationInstantCurWaitPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");




        sb.append(", stationInstantWalkingPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationInstantWalkingPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationInstantWalkingPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");




        sb.append(", stationTotalCurPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationTotalCurPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationTotalCurPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");


        sb.append(", stationTotalCurWantInputPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationTotalCurWantInputPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationTotalCurWantInputPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");


        sb.append(", stationTotalCurOutputPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationTotalCurOutputPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationTotalCurOutputPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");

        sb.append(", stationTotalCurWaitPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationTotalCurWaitPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationTotalCurWaitPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");


        sb.append(", stationTotalWalkingPersonNumMap={");
        for (Map.Entry<String, Integer> entry : stationTotalWalkingPersonNumMap.entrySet()) {
            sb.append(entry.getKey()).append(": ").append(entry.getValue()).append(", ");
        }
        if (!stationTotalWalkingPersonNumMap.isEmpty()) {
            sb.setLength(sb.length() - 2); // 移除最后的 ", "
        }
        sb.append("}");




        sb.append('}');
        return sb.toString();
    }
}
